//Granify Android SDK/com.granifyinc.granifysdk/Granify/setRestrictionState
setRestrictionState
[androidJvm]\
fun setRestrictionState(restrictionState: RestrictionState)
Tells Granify to enter/exit a restricted state in which no campaign can be shown to the shopper. Note that this does not apply to inline campaigns, which will not be hidden while in a restricted state.
The initial state of the SDK is UNRESTRICTED upon activation.
Placement
This function should be called:
- When entering a situation whereby a campaign should not be shown (excluding restricted page types).
- When exiting a situation whereby a campaign should not be shown (excluding navigating from restricted page types).
Parameters
androidJvm
restrictionState | The updated RestrictionState value indicating whether a campaign can be shown. |